<div class="content-table">
<div class="content-table-title"><?=$this->title?></div>
<div class="content-table-breadcrumb"><a href="/bk/topics"><返回</a></div>
<div class="form-edit-task">

<?php if($this->msg):?>
<div class="replace"><?=$this->msg?></div>
<?php endif;?>

<form action="/bk/edit-topic-submit" method="post" name="form1" onsubmit="return submitform(this)">
<span>标题：</span><input type="text" placeholder="标题" name="title" id="title" value="<?=$this->topic_info['title']?>">  <font>*</font><br/>
<span>正文：</span><script id="contents" type="text/plain" style="width:1024px;height:700px;"></script><br/>
<input type="hidden" name="topic_id" value="<?=$this->topic_info['topic_id']?>" />
<input type="submit" class="buttonlong" value="确认" />
<br /><br />
</form>
</div>
<br/><br/>
</div>

<script>
var ue = UE.getEditor('contents');

ue.ready(function() {
    //设置编辑器的内容
    ue.setContent('<?=$this->topic_info['contents']?>');
});

function submitform() 
{
	if( document.form1.title.value.length == 0 )
	{
		alert("标题不能为空。");
		return false;
	}
	
	form1.submit();
}
</script>